﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using imaginecup.information;

namespace Imaginecup.gameState.malaria.componentInit
{
    /// <summary>
    ///  ID값들을 이용해서 유연성을 부여.(ObjectMan가 모든 데이터를 관리할 수 있게 하는 근본)
    /// </summary>
  
    public class InterfaceID
    {
        public static SInterfaceID IID_ENTITY;
        public static SInterfaceID IID_RENDER ;
        
    }

    public class InterfaceIDMan
    {
        //Generator의 경우 정렬할때 어떻게 정렬하든 상관없이 만들기 위한 편의성을 제공하기 위해 사용.
        public static void GeneratorInterfaceID()
        {
            SInterfaceID.InitGenerator();

            InterfaceID.IID_ENTITY = SInterfaceID.IID_ENTITY;
            InterfaceID.IID_RENDER = SInterfaceID.IID_RENDER;
        }
    }

    public class MessageTypeIDMan
    {
        //Generator의 경우 정렬할때 어떻게 정렬하든 상관없이 만들기 위한 편의성을 제공하기 위해 사용.
        public static void GeneratorTypeID()
        {
            SMessageType.InitGenerator();

            MessageTypeID.MT_CHANGE_MALARIAPOSITION = SMessageType.Generator();
            MessageTypeID.MT_CHANGE_CHILDRENPOSITION = SMessageType.Generator();
            MessageTypeID.MT_CHILD_DIE = SMessageType.Generator();
            MessageTypeID.MT_MALARIA_DIE = SMessageType.Generator();

            MessageTypeID.MT_CHECK_INPUT = SMessageType.Generator();
            MessageTypeID.MT_SELECT_ITEM_DROP = SMessageType.Generator();
            MessageTypeID.MT_CHECK_ATTACK = SMessageType.Generator();//임시
            MessageTypeID.MT_CHECK_STATE = SMessageType.Generator();//임시
        }
    }


    public class MessageTypeID
    {
        public static SMessageType MT_CHANGE_MALARIAPOSITION;
        public static SMessageType MT_CHANGE_CHILDRENPOSITION;
        public static SMessageType MT_CHILD_DIE;
        public static SMessageType MT_MALARIA_DIE;

        public static SMessageType MT_CHECK_INPUT;
        

        public static SMessageType MT_SELECT_ITEM_DROP;
        public static SMessageType MT_CHECK_ATTACK;// 
        public static SMessageType MT_CHECK_STATE;
    }

    public class ComponentTypeIDMan
    {
        //Generator의 경우 정렬할때 어떻게 정렬하든 상관없이 만들기 위한 편의성을 제공하기 위해 사용.
        public static void GeneratorTypeID()
        {
            SComponentTypeID.InitGenerator();

            ComponentTypeID.CID_RENDER_MALARIA = SComponentTypeID.Generator();
            ComponentTypeID.CID_RENDER_CHILD = SComponentTypeID.Generator();
            ComponentTypeID.CID_RENDER_ITEMPANEL = SComponentTypeID.Generator();
            ComponentTypeID.CID_RENDER_TOP = SComponentTypeID.Generator();
            ComponentTypeID.CID_RENDER_FACTORYUI = SComponentTypeID.Generator();
            ComponentTypeID.CID_RENDER_PROGRESSBAR = SComponentTypeID.Generator();
            ComponentTypeID.CID_RENDER_COMPOSITE_PANEL = SComponentTypeID.Generator();
            ComponentTypeID.CID_RENDER_FIELD_ITEM = SComponentTypeID.Generator();
            ComponentTypeID.CID_RENDER_BACK = SComponentTypeID.Generator();

            ComponentTypeID.CID_MALARIA_ENTITY = SComponentTypeID.Generator();
            ComponentTypeID.CID_CHILDREN_ENTITY = SComponentTypeID.Generator();
            ComponentTypeID.CID_PANEL_ENTITY = SComponentTypeID.Generator();
            ComponentTypeID.CID_ITEM_ENTITY = SComponentTypeID.Generator();
            ComponentTypeID.CID_FIELD_ITEM_ENTITY = SComponentTypeID.Generator();
            ComponentTypeID.CID_FIELD_FROG_ENTITY = SComponentTypeID.Generator();


            ComponentTypeID.CID_OBSERVER_CHAR = SComponentTypeID.Generator();

            ComponentTypeID.CID_FIELD_SCENE = SComponentTypeID.Generator();
            ComponentTypeID.CID_MESSAGE_NONE = SComponentTypeID.Generator();
            ComponentTypeID.CID_ETC = SComponentTypeID.Generator();
        }
    }
    
    public class ComponentTypeID
    {
        public static SComponentTypeID CID_RENDER_BACK;
        public static SComponentTypeID CID_RENDER_MALARIA ;
        public static SComponentTypeID CID_RENDER_CHILD ;
        public static SComponentTypeID CID_RENDER_ITEMPANEL ;
        public static SComponentTypeID CID_RENDER_TOP ;
        public static SComponentTypeID CID_RENDER_FACTORYUI ;
        public static SComponentTypeID CID_RENDER_PROGRESSBAR ;
        public static SComponentTypeID CID_RENDER_COMPOSITE_PANEL ;
        public static SComponentTypeID CID_RENDER_FIELD_ITEM;
        
        public static SComponentTypeID CID_MALARIA_ENTITY;
        public static SComponentTypeID CID_CHILDREN_ENTITY ;        
        public static SComponentTypeID CID_PANEL_ENTITY ;
        public static SComponentTypeID CID_ITEM_ENTITY ;
        public static SComponentTypeID CID_FIELD_ITEM_ENTITY;
        public static SComponentTypeID CID_FIELD_FROG_ENTITY;

        public static SComponentTypeID CID_FIELD_SCENE;
        public static SComponentTypeID CID_MESSAGE_NONE;

        public static SComponentTypeID CID_OBSERVER_CHAR;

        public static SComponentTypeID CID_ETC ;
    }


    public class EnumIDInfomation
    {
        //이부분은 어쩔 수 없이 상수 정의 해야한다. 등록하기 전에 이 값이 이용되므로 등록되면서 자동으로 세어진 값을 얻어 사용할 수 없다 예) SComponentTypeID.GetGeneratorCount() -> X
        public static int NUM_INTERFACE_ID = 2;
        public static int NUM_MESSAGE_TYPE_IDS = 10;
        public static int NUM_COMPONENT_TYPE_IDS = 19;
    }
}
